package com.nulldev.util.uri.yt.rewrite;

import java.util.LinkedList;

import com.nulldev.util.java.JVMUtil;
import com.nulldev.util.other.ArrayUtils;
import com.nulldev.util.threading.v3.ThreadDispatcher;
import com.nulldev.util.threading.v3_extensions.Task;

public class RewriteDemo {

	public static void main(String[] args) {
		final Task<LinkedList<YoutubeVideo>> f = YoutubeExtractor2.EmbedAPIExtractor.generateTask("1RaKSRU60bw");
		ThreadDispatcher.instance().addTask(f);
		final LinkedList<YoutubeVideo> result = f.waitTillCompletion();
		JVMUtil.async_println("Result: ");
		ArrayUtils.printLln(result);
	}

}
